package day02;

import java.util.Arrays;

/**
 * Created by Administrator on 2023/6/30 0030.
 */
public class ArrayCopyDemo {
    public static void main(String[] args) {
        int[] a = {1, 2, 3, 4};
        int[] b = new int[]{3, 4, 5, 6};
//        int [] c=a;

        int[] c = new int[a.length];
        for (int i = 0; i < c.length; i++) {
            c[i] = a[i];
        }
//        int[] d = c.clone();

        System.out.println(a);
        System.out.println(b);
        System.out.println(c);
        a[0]++;
        System.out.println(Arrays.toString(a));
        System.out.println(Arrays.toString(b));
        System.out.println(Arrays.toString(c));

    }
}
